<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>

<!DOCTYPE HTML>
<html>
<head>
		<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
		<meta charset="utf-8">
		<meta name="author" content="chy">
		<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
		<meta http-equiv="description" content="This is my page">
		<!--手机头部-->
		<meta http-equiv="X-UA-Compatible" content="IE=8">
		<meta http-equiv="Cache-Control" content="max-age=0" />
		<meta name="MobileOptimized" content="240"/>
		<meta name="apple-touch-fullscreen" content="YES" />
		<meta content="yes" name="apple-mobile-web-app-capable" />
		<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no, minimal-ui" />
		<meta content="black" name="apple-mobile-web-app-status-bar-style" />
		<meta content="telephone=no" name="format-detection" />
		<link rel="shortcut icon" href="${baseContext}favicon.ico" />
<link type="text/css" rel="stylesheet" href="${baseContext}css/base.css">
<link type="text/css" rel="stylesheet" href="${baseContext}css/frame.css">
<title>互动答疑</title>
</head>
<body>
<!--header-->
 <%@ include file="header.jsp" %>
<!--header end-->

<!--frame-->
<div class="frame w1000">

  <!--frame-nav-->
	<%@ include file="LeftMenu.jsp" %>
  <!--frame-nav end-->
  
  <!--frame-cnt-->
  <div class="frame-cnt left">
    <!--面包屑-->
    <div class="crumbs">当前位置: 首页  >&nbsp;<a href="${baseContext}question/11.html" class="blue" title="互动答疑">互动答疑</a></div>
    <!--面包屑 end-->
    <!--cnt-box-->
    <div class="cnt-box">
      <!--list-title-->
      <div class="list-title blue"><span><i class="qa"></i>互动答疑</span></div>
      <!--list-title end-->
      <!--list-cnt-->
      <div class="list-cnt">
        <!--QA-list-->
        <s:iterator id="list" value="mapSug">
        <s:iterator id="suggestion" value="value" status="stat">
        <s:if test="#stat.index<2">
        <div class="qa-list">
         <p class="part"><s:property value="@org.util.string.StringUtils@subHtmlAndOther(contents,36,'...')"></s:property></p>
         <p><span>答</span>${answer}</p>
         </div>
         </s:if>
         <s:if test="#stat.index>1">
         <ul class="text-list"><li>
         <a href="${baseContext}answer/${id}.html" class="text-hide left" title="${contents}"><s:property value="@org.util.string.StringUtils@subHtmlAndOther(contents,30,'...')"></s:property></a>
         <span class="date right"><s:date name="createDate" format="yyyy-MM-dd" /></span></li></ul>
         </s:if>
        </s:iterator>
        <!--text-list
        <ul class="text-list">
          <li><a href="#" class="text-hide left" title="标题">关于印发哈尔滨市大学生创新创业工程实施方案的通知</a><span class="date right">2016-04-08</span></li>
          <li><a href="#" class="text-hide left" title="标题">关于印发哈尔滨市大学生创新创业工程实施方案的通知</a><span class="date right">2016-04-08</span></li>
          <li><a href="#" class="text-hide left" title="标题">关于印发哈尔滨市大学生创新创业工程实施方案的通知</a><span class="date right">2016-04-08</span></li>
        </ul>
        text-list end-->
        <!--翻页-->
        <div class="fenyepage">
          ${page_style }
		</div>
        </s:iterator>
        <!--翻页 end-->
        <!--我要提问-->
        <div class="question">
        <form id="i_form" method="post" >
          <p class="blue"> 我要提问</p>
          <p class="textarea"><textarea name="suggestion.contents"></textarea></p>
          <p class="overflow"><a href="#" id="sub">提交</a></p>
          </form>
        </div>
        <!--我要提问 end-->
      </div>
      <!--list-cnt end-->
    </div>
    <!--cnt-box end-->
  </div>
  <!--frame-cnt end-->
  
</div>
<!--frame end-->

<!--footer-->
<%@ include file="footer.jsp" %>
<!--footer end-->

<!--提交留言-->
<script type="text/javascript">
	$("#sub").click(function(){
	     $.post('${baseContext}newsHomeaddSuggestion.do',
	    	$('form').serialize(),
	  		function(data){
			  	var obj = JSON.parse(data); 
			    if(obj[0].success){
	  				alert(obj[0].msg);
	  				location.reload();
	  			}else{
	  				alert(obj[0].msg);
	  			}
		}); 
    });
</script>
</body>
</html>
